﻿@model GridPagedList<Product>
@using Domain
@using ASPMVCUtil.Helpers.Html.Grid
@using ASPMVCUtil.Models
@using ShowcaseMVC5.Models
@{
    ViewBag.Title = ShowcaseMVC5.GridResources.Title;
    Layout = "~/Views/Shared/_Layout.cshtml";
}

<h2>@Html.ActionLink(ShowcaseMVC5.HomeResources.ShowcaseTitle, "Showcase", "Home") > @ShowcaseMVC5.GridResources.Title > @ShowcaseMVC5.GridResources.Complete</h2>

<fieldset>
    <legend>@ShowcaseMVC5.GridResources.Products</legend>
@{
    IEnumerable<GridColumn<Product>> columnas = new GridColumn<Product>[] {
        GridColumn<Product>.create("Id", "70", false,
            new GridCellTemplateIcon<Product>(Url.Content("~/Images/id.png"))),
        GridColumn<Product>.create("Name", "*", false,  null, new string[] { "centered" }),
        GridColumn<Product>.create("Price", "100", false, new PriceTemplate<Product>()),
        GridColumn<Product>.create("Release", "110", false, new DateTemplate <Product>()),
        GridColumn<Product>.create("Quantity", "100", false, new QuantityTemplate<Product>())
    };
}
@Html.Grid(columnas, Model, "Default", GridPagerPosition.Both, 0, false, false, false, false, null, new GridRowFormatterImplProduct())
</fieldset>

<h3>About this example</h3>
<script type="text/javascript">
    $(function () {
        $("#tabs").tabs();
    });
</script>
<div id="tabs">
	<ul>
		<li><a href="#tabs-1">Description</a></li>
		<li><a href="#tabs-2">View</a></li>
		<li><a href="#tabs-3">Controller</a></li>
		<li><a href="#tabs-4">Model</a></li>
		<li><a href="#tabs-5">Options</a></li>
	</ul>
	<div id="tabs-1">
		<p>The Grid widget is a ASP.NET MVC 5 great complement!</p>
	</div>
	<div id="tabs-2">
        <pre>

        </pre>
	</div>
	<div id="tabs-3">
        <pre class="brush: csharp">

        </pre>
	</div>
	<div id="tabs-4">
        <pre>

        </pre>
	</div>
	<div id="tabs-5">
	</div>
</div>